// 对象
export declare type ObjectType = Record<string, any>;

// 分页
export interface Pagination<T = number> {
  current: T;
  size: T;
  total: T;
  pages?: T;
}

export type Code = 200 | 201 | 202 | 401;

export interface ResponseData<T = any> {
  code: Code;
  status?: boolean;
  data: T;
  msg: string;
}

export type ResponseRecordsData = Pagination & {
  order: unknown[];
  searchCount: boolean;
  records: ObjectType[];
};

export enum DialogType {
  Add,
  Edit,
}
